package com.bwie.common.pojo;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 订单表
 * </p>
 *
 * @author liuxin
 * @since 2025-04-21
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_orders")
@ApiModel(value="TOrders对象", description="订单表")
public class Orders implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "订单ID")
    @TableId(value = "order_id", type = IdType.AUTO)
    private Long orderId;

    @ApiModelProperty(value = "订单编号")
    private String orderNumber;

    @ApiModelProperty(value = "用户ID")
    private Long userId;

    @ApiModelProperty(value = "发货方式ID")
    private Long shippingMethodId;

    @ApiModelProperty(value = "订单状态（0:待付款, 1:待发货, 2:已发货, 3:运输中, 4:已完成, 5:退款中, 6:已关闭）")
    private Integer orderStatus;

    @ApiModelProperty(value = "下单时间")
    private LocalDateTime orderTime;

    @ApiModelProperty(value = "支付时间")
    private LocalDateTime paymentTime;

    @ApiModelProperty(value = "发货时间")
    private LocalDateTime shippingTime;

    @ApiModelProperty(value = "确认收货时间")
    private LocalDateTime deliveryTime;

    @ApiModelProperty(value = "订单金额")
    private BigDecimal orderAmount;

    @ApiModelProperty(value = "商品数量")
    private Integer productQuantity;

    @ApiModelProperty(value = "收货人信息")
    private String recipientInfo;

    @ApiModelProperty(value = "发货地址")
    private String shippingAddress;

    @ApiModelProperty(value = "物流信息")
    private String logisticsInfo;

    @ApiModelProperty(value = "支付状态（0:未支付, 1:已支付, 2:支付失败）")
    private Integer paymentStatus;

    @ApiModelProperty(value = "逻辑删除（0:未删除, 1:已删除）")
    private Integer isDeleted;

    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createdAt;

    @ApiModelProperty(value = "修改时间")
    private LocalDateTime updatedAt;


}
